while True:
    try:
        print('You can enter "b" to end.')
        number_a = input('Enter a number: ')
        number_b = input('Enter another number: ')
        if number_a == 'b' or number_b == 'b':
            break
        number_a = int(number_a)
        number_b = int(number_b)
    except ValueError:
        print('You do not enter two numbers.')
    else:
        print(number_a + number_b)